Isn't objective-c function parameter syntax weird? [closed]
Posted
by
Haoest
on Stack Overflow
See other posts from Stack Overflow
or by Haoest
Published on 2011-03-13T07:38:36Z
Indexed on
2011/03/13
8:10 UTC
Read the original article
Hit count: 207
objective-c
Consider the following method:
+(void) myMethod:(int)arg1 **argument2**(int)arg2 **argument3**(int) arg3;
See how the first argument, unlike the 2nd and 3rd, doesn't have a description, giving it an impression of bad symmetry. Also you would expect the extra typing will provide named argument as you pass it in, but you still have to pass them in the correct order.
Can anyone help me make sense of this?
© Stack Overflow or respective owner